<template>
	<view class="status">
		<xbd-pages-content :title="title">
			<template #content>
				<view class="content">
					<view class="icon">
						<image v-if="pass" src="../../static/images/meal/pass.svg" mode=""></image>
						<image v-if="!pass" src="../../static/images/meal/refuse.svg" mode=""></image>
					</view>
					<view class="text">
						<view class="">
							{{msg}}
						</view>
					</view>
						<view class="button" @click="back">
							返回列表
						</view>
				</view>
			</template>
		</xbd-pages-content>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				pass:true, //判断 审批通过或者拒绝审批
				title:'',  // 审批页面title
				msg:'' // 审批提示文字
				
			};
		},
		methods: {
			back(){
				uni.navigateBack({
					delta: 1
				});
			}
		},
		computed: {


		},
		onLoad(res){
			// 传入 pass  title   msg
			const info = JSON.parse(res.option);
			this.pass=info.pass
			this.title=info.title
			this.msg=info.msg
			uni.setNavigationBarTitle({
			    title: this.title
			});
		}
	}
</script>

<style lang="scss" scoped>
	.content{
		padding: 30px 50rpx;
		.icon{
			margin-top: 100px;
			text-align: center;
			image{
				width: 200rpx;
				height: 200rpx;
			}
		}
		.text{
			margin-top: 30px;
			text-align: center;
			margin-bottom: 80px;
		}
		.button{
			width: 650rpx;
			height: 32px;
			background:url(../../static/images/common/bluebg.png)  no-repeat;
			background-size:100% 100%;
			color: $uni-text-color-inverse;	
			font-size: 28rpx;
			line-height: 32px;
			border-radius: 8rpx;
			text-align: center;
		}
	}
</style>
